Add<TService>(TService) Method

Summary
Adds a service into the collection with a specific type.
Syntax
C#
VB
C++
public void Add<TService>( 
   TService serviceInstance 
) 
  
Public Overloads Sub Add(Of TService)( _ 
   ByVal serviceInstance As TService _ 
)  
public: 
void Addgeneric<typename TService> 
(  
   _TService^_ serviceInstance 
)  

Parameters

serviceInstance
A service to be added into the collection.

Type Parameters

TService
The type of the serviceInstance to be added.

Remarks

If another service exists with the same type this method will throw an System.InvalidOperationException.

Requirements

Target Platforms

Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Medical.Workstation Assembly

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.